'''
Created on Nov 26, 2010

@author: behrooz
'''
from amscms import settings
from amscms.core.views import update_global_stats
from django.core.management.base import BaseCommand

class Command(BaseCommand):
    
    help = "Updates the global stats displayed in the bottom of AMS pages"
    
    def handle(self, *args, **options):
        '''
        Simply runs core/views.py#update_global_stats function
        '''
        from django.utils import translation
        translation.activate(settings.LANGUAGE_CODE)
        update_global_stats(None)
        return
    
